#include"game.h"
#include"tools.h"

int main()
{
	srand((unsigned int)time(NULL));
	
	gameInit();

	int timer = 0;
	bool flag = 1;
	startUI();

	while (1)
	{
		userClick();
		timer += getDelay();
		if (timer > 50)
		{
			flag = 1;
			timer = 0;
		}

		if (flag)
		{
			flag = 0;
			updateWindow();
			updateGame();
		}

		Sleep(1);
	}


	system("pause");
	return 0;
}


